package com.cts.controller;

import com.cts.entity.Tag;
import com.cts.model.vo.Result;
import com.cts.service.TagService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @projectName: CBlog
 * @package: com.cts.controller.admin
 * @className: TagController
 * @author: chentongsheng
 * @description: TODO
 * @date: 2023/4/9 21:56
 * @version: 1.0
 */
@RestController
@RequestMapping("/tag")
public class TagController {

    @Autowired
    TagService tagService;

    @RequestMapping("/getTagList")
    public Result getTagList() {
        List<Tag> list = tagService.list();
        return Result.ok("请求成功", list);
    }
}
